package thinkingJava.chapter19;


import static util.Print.*;
import static thinkingJava.chapter19.AlarmPoints.*;
import java.util.EnumSet;

public class EnumSets {
	public static void main(String[] args) {
		EnumSet<AlarmPoints> points = EnumSet.noneOf(AlarmPoints.class);
		points.add(BATHROOM);
		print(points);
		points.addAll(EnumSet.of(START1,START2,KITCHEN));
		print(points);
		points = EnumSet.allOf(AlarmPoints.class);
		points.removeAll(EnumSet.of(START1,START2,KITCHEN));
		print(points);
		points.removeAll(EnumSet.range(OFFICE1, OFFICE4));
		print(points);
		points = EnumSet.complementOf(points);
		print(points);
	}
}
